package com.ztesoft.ossup.report.domain;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.SequenceGenerator;


@Entity
public class ReportChartData implements Serializable {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public ReportChartData() {
		// TODO Auto-generated constructor stub
	}
	@Id
	@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "REPORT_CHART_DATA_SEQ")
	@SequenceGenerator(name = "REPORT_CHART_DATA_SEQ", sequenceName = "REPORT_CHART_DATA_SEQ")
	public Long id;
	
	@ManyToOne(fetch = FetchType.EAGER)
    @JoinColumn(name = "chartId", referencedColumnName = "id")
    public ReportChart chart;
	
	@Column(nullable=false,length=128)
	public String label;
	
	@Column(nullable=false,length=1)
	public String isFill;
	
	@Column(nullable=false,length=128)
	public String backgroundColor = "rgba(240,240,240,1)";// rgba(80,20,90,1)

	public String getLabel() {
		return label;
	}

	public void setLabel(String label) {
		this.label = label;
	}

	public String getBackgroundColor() {
		return backgroundColor;
	}

	public void setBackgroundColor(String backgroundColor) {
		this.backgroundColor = backgroundColor;
	}

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public ReportChart getChart() {
		return chart;
	}

	public void setChart(ReportChart chart) {
		this.chart = chart;
	}

	public String getIsFill() {
		return isFill;
	}

	public void setIsFill(String isFill) {
		this.isFill = isFill;
	}

	
	
}
